Developer Documentation

QuickTime 4 API Documentation

3D Graphics Programming with QuickDraw 3D 1.5.4

Previous | QD3D Book | Overview | Chapter Contents | Next |

Managing Shadow-Receiving Styles

QuickDraw 3D provides routines that you can use to manage shadow-receiving styles.

Q3ReceiveShadowsStyle_New

You can use the Q3ReceiveShadowsStyle_New function to create a new shadow-receiving style object.

TQ3StyleObject Q3ReceiveShadowsStyle_New (TQ3Boolean receives);
receives
A Boolean value that determines whether the new style object specifies that objects in the scene receive shadows ( kQ3True ) or do not receive shadows ( kQ3False ).

DESCRIPTION

The Q3ReceiveShadowsStyle_New function returns, as its function result, a new style object having the shadow-receiving style specified by the receives parameter.

If a new style object could not be created, Q3ReceiveShadowsStyle_New returns the value NULL .

To change the current shadow-receiving style, you must actually draw the style object. You can call Q3Style_Submit to draw the style in retained mode or Q3ReceiveShadowsStyle_Submit (described next) to draw the style in immediate mode.

SEE ALSO

See "Shadow-Receiving Styles" for a description of shadow-receiving styles.

Q3ReceiveShadowsStyle_Submit

You can use the Q3ReceiveShadowsStyle_Submit function to submit a shadow-receiving style in immediate mode.

TQ3Status Q3ReceiveShadowsStyle_Submit (
                     TQ3Boolean receives,
                     TQ3ViewObject view);
receives
A Boolean value that determines whether objects in the scene receive shadows ( kQ3True ) or do not receive shadows ( kQ3False ).
view
A view.

DESCRIPTION

The Q3ReceiveShadowsStyle_Submit function sets the shadow-receiving style of the view specified by the view parameter to the style specified by the receives parameter.

SPECIAL CONSIDERATIONS

You should call Q3ReceiveShadowsStyle_Submit only in a submitting loop.

Q3ReceiveShadowsStyle_Get

You can use the Q3ReceiveShadowsStyle_Get function to get the shadow-receiving style value of a shadow-receiving style.

TQ3Status Q3ReceiveShadowsStyle_Get (
                     TQ3StyleObject styleObject,
                     TQ3Boolean *receives);
styleObject
A shadow-receiving style object.
receives
On exit, a pointer to the shadow-receiving style value of the specified shadow-receiving style object.

DESCRIPTION

The Q3ReceiveShadowsStyle_Get function returns, in the receives parameter, a pointer to the current shadow-receiving style value of the style object specified by the styleObject parameter.

Q3ReceiveShadowsStyle_Set

You can use the Q3ReceiveShadowsStyle_Set function to set the shadow-receiving style value of a shadow-receiving style.

TQ3Status Q3ReceiveShadowsStyle_Set (
                     TQ3StyleObject styleObject,
                     TQ3Boolean receives);
styleObject
A shadow-receiving style object.
receives
A Boolean value that determines whether objects in the scene receive shadows ( kQ3True ) or do not receive shadows ( kQ3False ).

DESCRIPTION

The Q3ReceiveShadowsStyle_Set function sets the shadow-receiving style value of the style object specified by the styleObject parameter to the value specified in the receives parameter.


© 1997 Apple Computer, Inc.

Previous | QD3D Book | Overview | Chapter Contents | Next |